Computer systems typically comprise a combination of computer programs and hardware, such as semiconductors, transistors, chips, circuit boards, storage devices, and processors. The computer programs are stored in the storage devices and are executed by the processors. Fundamentally, computer systems are used for the storage, manipulation, and analysis of data. One mechanism for managing data is called a database management system (DBMS), which may also be called a database system or simply a database.
Many different types of databases are known, but the most common is usually called a relational database (RDB), which organizes data in tables that have rows, which represent individual entries, tuples, or records in the database, and columns, fields, or attributes, which define what is stored in each row, entry, tuple, or record. Each table has a unique name within the database and each column has a unique name within the particular table. The database also has an index, which is a data structure that informs the database management system of the location of a certain row in a table given an indexed column value, analogous to a book index informing the reader on which page a given word appears. The database accesses the data in a row via a key. A key specifies the name of a column and a data value that exists in one of the rows in that column.
Data in databases is often replicated on multiple server computers, in order to provide enhanced performance, reliability, and to provide the ability to respond to a variable rate of requests from client computers. For example, an online store may have several servers, each of which may include replicated data regarding the inventory that is in stock and available for sale. Some replicated databases replicate the entire database while others replicate only a portion of the data and store the replicated data in volatile memory, such as a cache, as opposed to storing the replicated data in non-volatile memory, such as a disk drive or other secondary storage. Databases that primarily rely on volatile memory are known as in-memory databases (IMDB) or main memory databases (MMDB). Accessing data from a cache typically provides faster and more predictable performance than does secondary storage.
Data that is replicated in multiple caches needs to be kept synchronized or consistent. For example, if a client buys an inventory item via a request to one server, the inventory data at that server is easily decremented, in order to reflect that the number of items in stock has decreased by one. But, the inventory data at the other servers is now out-of-date or “stale” and also needs to be decremented, in order to keep the replicated data across all servers synchronized and up-to-date. The process of keeping multiple caches synchronized is often called cache coherency.